package org.jgs1904.publisherandlistener.controller;

import org.jgs1904.publisherandlistener.publisher.MyTestEventPubLisher;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author: 默苍璃
 * @date: 2023-11-03 18:39
 */
@RestController
public class TestEventListenerController {

    @Autowired
    private MyTestEventPubLisher publisher;

    @RequestMapping(value = "/test/testPublishEvent1")
    public void testPublishEvent() {
        publisher.pushListener("我来了！");
    }

}
